#pragma once
#include "AccountDef\AccountLoginDef.h"

enum G2C_PROTOCAL
{
    g2c_handshake_respond,
    g2c_accound_login_respond,
    g2c_sync_login_info,

    g2c_protocal_total
};

#pragma pack(1)

struct XG2CHeader
{
    BYTE byProtocol;
};

struct G2C_HANDSHAKE_RESPOND : public XG2CHeader 
{
    int16_t nReturnCode;
    char    szRandomKey[RANDOM_STRING_SIZE];
};

struct G2C_ACCOUNT_LOGIN_RESPOND : public XG2CHeader 
{
    BYTE byResult;
};

struct G2C_SYNC_LOGIN_INFO : public XG2CHeader
{
    char    szIP[MAX_IP_ADDRESS_LEN];
    int16_t nPort;
};

#pragma pack()